package com.qf.flash.http.response;

import android.os.Parcel;
import android.os.Parcelable;

/**
 * 2020/3/11 16:49
 */
public class PlayTypeBean implements Parcelable {

    /**
     * id : 3
     * name : 狼人杀
     * templateId : 3
     * image : http://q61e7nyr3.bkt.clouddn.com/game/type/3.png
     * downpayment : 30
     */

    private String id;
    private String name;
    private String templateId;
    private String image;
    private double downpayment;

    protected PlayTypeBean(Parcel in) {
        id = in.readString();
        name = in.readString();
        templateId = in.readString();
        image = in.readString();
        downpayment = in.readDouble();
    }

    public static final Creator<PlayTypeBean> CREATOR = new Creator<PlayTypeBean>() {
        @Override
        public PlayTypeBean createFromParcel(Parcel in) {
            return new PlayTypeBean(in);
        }

        @Override
        public PlayTypeBean[] newArray(int size) {
            return new PlayTypeBean[size];
        }
    };

    public String getId() {
        return id == null ? "" : id;
    }

    public void setId(String id) {
        this.id = id;
    }

    public String getName() {
        return name == null ? "" : name;
    }

    public void setName(String name) {
        this.name = name;
    }

    public String getTemplateId() {
        return templateId == null ? "" : templateId;
    }

    public void setTemplateId(String templateId) {
        this.templateId = templateId;
    }

    public String getImage() {
        return image == null ? "" : image;
    }

    public void setImage(String image) {
        this.image = image;
    }

    public double getDownpayment() {
        return downpayment;
    }

    public void setDownpayment(double downpayment) {
        this.downpayment = downpayment;
    }

    @Override
    public int describeContents() {
        return 0;
    }

    @Override
    public void writeToParcel(Parcel dest, int flags) {
        dest.writeString(id);
        dest.writeString(name);
        dest.writeString(templateId);
        dest.writeString(image);
        dest.writeDouble(downpayment);
    }
}
